using IM.Easy.Entity.Msg;
using IM.Easy.Infrastructure.Query;
using System.ComponentModel.DataAnnotations;


namespace IM.Easy.MsgServices.Dtos
{
    /// <summary>
    /// 邮件表查询实体
    /// </summary>
    public class EmailsQueryDto : QueryBase
    {
        /// <summary>
        /// 邮件主题
        /// </summary>
        public string Subject { get; set; }

        /// <summary>
        /// 邮件状态 (0: 草稿, 1: 已发送, 2: 已撤回，-1：已删除)
        /// </summary>
        public EmailStatus? Status { get; set; }

        /// <summary>
        /// 发送方
        /// </summary>
        public long SenderId { get; set; }
    }

    /// <summary>
    /// 邮件表dto
    /// </summary>
    public class EmailsDto
    {
        /// <summary>
        /// 邮件唯一标识
        /// </summary>
        public long Id { get; set; }
        /// <summary>
        /// 发件人用户ID
        /// </summary>
        public long SenderId { get; set; }
        /// <summary>
        /// 邮件主题
        /// </summary>
        public string Subject { get; set; }
        /// <summary>
        /// 邮件正文
        /// </summary>
        public string Body { get; set; }

        /// <summary>
        /// 邮件正文摘要
        /// </summary>
        public string Abstract { get; set; }

        /// <summary>
        /// 发送时间
        /// </summary>
        public DateTime? SentTime { get; set; }
        /// <summary>
        /// 邮件状态 (0: 草稿, 1: 已发送, 2: 已撤回，-1：已删除)
        /// </summary>
        public EmailStatus Status { get; set; }

        /// <summary>
        /// 接收方
        /// </summary>
        public List<long> AudienceId { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreatedAt { get; set; }
        /// <summary>
        /// 创建人ID
        /// </summary>
        public long CreatedBy { get; set; }
        /// <summary>
        /// 更新时间
        /// </summary>
        public DateTime? UpdatedAt { get; set; }
        /// <summary>
        /// 更新人ID
        /// </summary>
        public long UpdatedBy { get; set; }
        /// <summary>
        /// 是否已删除
        /// </summary>
        public byte IsDeleted { get; set; }
        /// <summary>
        /// 删除人ID
        /// </summary>
        public long DeletedBy { get; set; }
        /// <summary>
        /// 删除时间
        /// </summary>
        public DateTime? DeletedAt { get; set; }
    }
}
